/*
ID:luongho3
LANG:C++
TASK:barn1
*/
#include <iostream>
#include <fstream>
#include <queue>
#include <vector>
#include <algorithm>
using namespace std;
ifstream fin("barn1.in");
ofstream fout("barn1.out");
typedef vector<int> iVector;
typedef priority_queue<int> iMaxHeap;
iVector cowNumberList;
iMaxHeap distanceHeap;
int boardNumber,stallNumber,cowNumber;
main() {
       fin>>boardNumber>>stallNumber>>cowNumber;
       int i;
       for (i=0;i<cowNumber;++i) {
           int temp;
           fin>>temp;
           cowNumberList.push_back(temp);    
       }
       sort(cowNumberList.begin(),cowNumberList.end());
       for (i=1;i<cowNumber;++i) {
           int temp=cowNumberList[i]-cowNumberList[i-1]-1;
           distanceHeap.push(temp);
       }
       int nBlockedStall=cowNumberList[cowNumberList.size()-1]-cowNumberList[0]+1;
       int nBoardUsed=1;
       while (nBoardUsed<boardNumber) {
             if (!distanceHeap.empty()) {
                ++nBoardUsed;
                int temp=distanceHeap.top();
                nBlockedStall-=distanceHeap.top();
                distanceHeap.pop();
             }
             else {
                  break;
             }      
       }
       fout<<nBlockedStall<<"\n";
       return 0;
}
